/*
 * @Date: 2023-02-08 11:28:31
 * @LastEditTime: 2023-02-20 09:56:27
 * @FilePath: /hash-guess-game/src/router/module/tabbar.ts
 * 介绍:底部导航路由
 */

import type { RouteRecordRaw } from "vue-router";
import { useI18n } from "@@/hooks/useI18n";
import { DialogRouter, TabbarRouter } from "../interface";
const { t } = useI18n();

const routes: Array<
  (RouteRecordRaw & TabbarRouter) & (RouteRecordRaw & DialogRouter)
> = [
  {
    name: "home",
    path: "/home",
    component: () => import("@@/views/home/home.vue"),
    meta: {
      title: t("shou-ye"),
      tabbar: {
        fontIconActive: "wap-home-o",
        fontIcon: "wap-home",
      },
    },
    children: [
      {
        name: "safeBox",
        path: "/home/safeBox",
        component: () => import("@@/views/home/safeBox.vue"),
        meta: {
          title: t("bao-xian-xiang"),
          dialog: {
            okBtnText: t("chong-zhi"),
            noBtnText: t("ti-qu"),
          },
        },
      },
      {
        name: "drawMoney",
        path: "/home/drawMoney",
        component: () => import("@@/views/home/drawMoney.vue"),
        meta: {
          title: t("ti-qu"),
          dialog: {
            showBack: true,
            footer: t("ti-qu-ji-lu"),
          },
        },
      },
      {
        name: "topUpMoney",
        path: "/home/topUpMoney",
        component: () => import("@@/views/home/topUpMoney.vue"),
        meta: {
          title: t("chong-zhi"),
          dialog: {
            showBack: true,
            footer: t("chong-zhi-ji-lu"),
          },
        },
      },
    ],
  },
  {
    name: "club",
    path: "/club",
    component: () => import("@@/views/club/club.vue"),
    meta: {
      title: t("ju-le-bu"),
      tabbar: {
        fontIconActive: "friends-o",
        fontIcon: "friends",
      },
    },
  },
  {
    name: "myCenter",
    path: "/myCenter",
    component: () => import("@@/views/myCenter/myCenter.vue"),
    meta: {
      title: t("ge-ren-zhong-xing"),
      tabbar: {
        fontIconActive: "manager-o",
        fontIcon: "manager",
      },
    },
  },
];
export default routes;
